package tank;

/**
 * @Auther: fei
 * @Date: 2021/6/17 - 06 - 17 - 21:43
 * @Description: tank
 * @version: 1.0
 */
public class DefaultFireStrategy implements FireStrategy {


    public void fire(Tank t){
        int bX = t.x + Tank.WIDTH/2 - Bullet.WIDTH/2;
        int bY = t.y + Tank.HEIGHT/2 - Bullet.HEIGHT/2;

        new Bullet(bX,bY,t.dir,t.tf,t.group); //从坦克位置发射子弹
    }
}
